package router

import (
	"YingShop/controller"
	"YingShop/middleware"

	"github.com/gin-gonic/gin"
)

func LoadCategoryRoute(e *gin.Engine) {
	productCategoryRouteGroup := e.Group("/productCategory")
	productCategoryRouteGroup.Use(middleware.LoginMiddleWare())
	productCategoryRouteGroup.GET("/:categoryId", controller.ProductCategoryController{}.Get)
	productCategoryRouteGroup.POST("", controller.ProductCategoryController{}.Post)
	productCategoryRouteGroup.GET("", controller.ProductCategoryController{}.GetAllCategory)
}
